import request from '@/utils/request'
const api_name = "/video"
export default {
    addList(data) {
        return request({
            url: `${api_name}`,
            method: 'post',
            data: data
        })
    },
    // 删除数据
    delList(id) {
        return request({
            url: `${api_name}/${id}`,
            method: 'delete'
        })
    },
    // 根据id获取数据
    getList(id) {
        return request({
            url: `${api_name}/${id}`,
            method: 'get'
        })
    },
    // 修改数据
    updateList(data) {
        return request({
            url: `${api_name}/${data.id}`,
            method: 'put',
            data: data
        })
    }
}